-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Geyser: return real parent blockhash, or default #33873
Geyser: return real parent blockhash, or default #33873
Conversation
Codecov Report
@@ Coverage Diff @@
## master #33873 +/- ##
=========================================
- Coverage 81.9% 81.9% -0.1%
=========================================
Files 810 810
Lines 219291 219293 +2
=========================================
- Hits 179691 179667 -24
- Misses 39600 39626 +26 |
507cefc
to
9892266
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch!
I am proposing a v1.17 backport of this one, since it is a bug fix to geyser data |
Return real parent blockhash, or default (cherry picked from commit d6ac9be)
…33873) (#33959) Geyser: return real parent blockhash, or default (#33873) Return real parent blockhash, or default (cherry picked from commit d6ac9be) Co-authored-by: Tyera <[email protected]>
…olana-labs#33873) (solana-labs#33959) Geyser: return real parent blockhash, or default (solana-labs#33873) Return real parent blockhash, or default (cherry picked from commit d6ac9be) Co-authored-by: Tyera <[email protected]>
…olana-labs#33873) (solana-labs#33959) Geyser: return real parent blockhash, or default (solana-labs#33873) Return real parent blockhash, or default (cherry picked from commit d6ac9be) Co-authored-by: Tyera <[email protected]>
Problem
Geyser's
notify_block_metadata()
callsBank::parent_hash()
to populate itsparent_blockhash
field. ButBank::parent_hash()
returns a bank hash, not a blockhash (ie. latest blockhash in the bank).Summary of Changes
Update code to get the correct parent_blockhash. This currently includes an
unwrap_or_default
, becauseBank::parent()
returns an Option. Before merging this, we need to understand in what situations the parent bank would be None when this notification is triggered.Fixes #33829